package com.cskaoyan.controller;

import com.cskaoyan.bean.VO.WxBrandVo;
import com.cskaoyan.bean.common.BaseRespVo;
import com.cskaoyan.bean.common.CommonData;
import com.cskaoyan.service.WxBrandService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author:zhangjiaxin
 **/
@RestController
@RequestMapping("wx/brand")
public class WxBrandController {
    @Autowired
    WxBrandService wxBrandService;

    @RequestMapping("list")
    public BaseRespVo list(Integer page, Integer limit) {
        CommonData data = wxBrandService.queryBrandList(page, limit);
        return BaseRespVo.ok(data);
    }
    @RequestMapping("detail")
    public BaseRespVo detail(Integer id) {
        WxBrandVo data = wxBrandService.queryBrandById(id);
        return BaseRespVo.ok(data);
    }
}
